package gui;

import java.awt.EventQueue;

import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.border.EmptyBorder;

import fachada.LojaDiscos;
import javax.swing.JTextPane;
import javax.swing.JToggleButton;
import javax.swing.JLabel;
import java.awt.Font;
import java.io.IOException;

import javax.swing.JComboBox;
import javax.swing.JTextField;
import javax.swing.JButton;
import java.awt.event.ActionListener;
import java.awt.event.ActionEvent;

public class FrameLojaDiscos extends JFrame {
	private static final long serialVersionUID = 1L;

	private JPanel contentPane;
	private LojaDiscos fachada;
	private FrameCdCadastrar cdCadastro;

	/**
	 * Launch the application.
	 */
	public static void main(String[] args) {
		EventQueue.invokeLater(new Runnable() {
			public void run() {
				try {
					FrameLojaDiscos frame = new FrameLojaDiscos();
					frame.setVisible(true);
				} catch (Exception e) {
					e.printStackTrace();
				}
			}
		});
	}

	/**
	 * Create the frame.
	 * @throws IOException 
	 */
	public FrameLojaDiscos() throws IOException {
		fachada = new LojaDiscos();
		
		try {
			cdCadastro = new FrameCdCadastrar(fachada);
		} catch (IOException e) {
			e.printStackTrace();
		}
		
				
		setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		setBounds(100, 100, 450, 300);
		contentPane = new JPanel();
		contentPane.setToolTipText("");
		contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));
		setContentPane(contentPane);
		contentPane.setLayout(null);
		
		JLabel lojaDiscos = new JLabel("Loja de Discos");
		lojaDiscos.setFont(new Font("Eras Demi ITC", Font.PLAIN, 20));
		lojaDiscos.setBounds(149, 55, 145, 31);
		contentPane.add(lojaDiscos);
		
		JLabel lblCadastro = new JLabel("Selecione o tipo de dados desejado:");
		lblCadastro.setFont(new Font("Tahoma", Font.PLAIN, 12));
		lblCadastro.setBounds(115, 112, 210, 19);
		contentPane.add(lblCadastro);
		
		JButton btnCd = new JButton("CD");
		btnCd.setBounds(55, 142, 89, 38);
		contentPane.add(btnCd);
		
		JButton btnDvd = new JButton("DVD");
		btnDvd.setBounds(172, 142, 89, 38);
		contentPane.add(btnDvd);
		
		JButton btnCliente = new JButton("Cliente");
		btnCliente.setBounds(286, 142, 89, 38);
		contentPane.add(btnCliente);
	}
}
